/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package org.foment.gem.statistic;

import java.sql.Connection;
import java.sql.ResultSet;
import java.sql.SQLException;
import org.foment.gem.statistic.Employee;
import org.foment.joliage3.sql.Database;

/**
 *
 * @author Dusan
 */
public class StatisticTestMain {
    public static void main(String []a) throws SQLException
    {
        String query = "SELECT * FROM Employee ORDER BY EmployeeFirstName";
        Connection  conn = Database.getConnection();
        ResultSet rs = conn.createStatement().executeQuery(query);
        while (rs.next())
        {
            Employee e = new Employee(rs.getInt("EmployeeID"));
            e.setValues(rs);
            System.out.println(e);
        }
        rs.close();
        conn.close();
        //new StatisticsDialog();
    }
}
